package com.navi.loaddata.core.mysqlEntity;

import javax.persistence.*;
import java.sql.Timestamp;

/**
 * Created by ghost on 2018/5/31.
 */
@Entity
@Table(name = "eda_diff_d", schema = "ch_qms", catalog = "")
public class EdaDiffD {
    private int id;
    private String shop;
    private String ope;
    private String eqpt;
    private Timestamp evtStartTimestamp;
    private Timestamp evtEndTimestamp;
    private Integer gpCnt;
    private Integer oraCnt;
    private Integer difference;
    private Timestamp updateTime;
    private String remark;

    @Id
    @Column(name = "ID")
    public int getId() {
        return id;
    }

    public void setId(int id) {
        this.id = id;
    }

    @Basic
    @Column(name = "SHOP")
    public String getShop() {
        return shop;
    }

    public void setShop(String shop) {
        this.shop = shop;
    }

    @Basic
    @Column(name = "OPE")
    public String getOpe() {
        return ope;
    }

    public void setOpe(String ope) {
        this.ope = ope;
    }

    @Basic
    @Column(name = "EQPT")
    public String getEqpt() {
        return eqpt;
    }

    public void setEqpt(String eqpt) {
        this.eqpt = eqpt;
    }

    @Basic
    @Column(name = "EVT_START_TIMESTAMP")
    public Timestamp getEvtStartTimestamp() {
        return evtStartTimestamp;
    }

    public void setEvtStartTimestamp(Timestamp evtStartTimestamp) {
        this.evtStartTimestamp = evtStartTimestamp;
    }

    @Basic
    @Column(name = "EVT_END_TIMESTAMP")
    public Timestamp getEvtEndTimestamp() {
        return evtEndTimestamp;
    }

    public void setEvtEndTimestamp(Timestamp evtEndTimestamp) {
        this.evtEndTimestamp = evtEndTimestamp;
    }

    @Basic
    @Column(name = "GP_CNT")
    public Integer getGpCnt() {
        return gpCnt;
    }

    public void setGpCnt(Integer gpCnt) {
        this.gpCnt = gpCnt;
    }

    @Basic
    @Column(name = "ORA_CNT")
    public Integer getOraCnt() {
        return oraCnt;
    }

    public void setOraCnt(Integer oraCnt) {
        this.oraCnt = oraCnt;
    }

    @Basic
    @Column(name = "DIFFERENCE")
    public Integer getDifference() {
        return difference;
    }

    public void setDifference(Integer difference) {
        this.difference = difference;
    }

    @Basic
    @Column(name = "UPDATE_TIME")
    public Timestamp getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Timestamp updateTime) {
        this.updateTime = updateTime;
    }

    @Basic
    @Column(name = "REMARK")
    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        EdaDiffD edaDiffD = (EdaDiffD) o;

        if (id != edaDiffD.id) return false;
        if (shop != null ? !shop.equals(edaDiffD.shop) : edaDiffD.shop != null) return false;
        if (ope != null ? !ope.equals(edaDiffD.ope) : edaDiffD.ope != null) return false;
        if (eqpt != null ? !eqpt.equals(edaDiffD.eqpt) : edaDiffD.eqpt != null) return false;
        if (evtStartTimestamp != null ? !evtStartTimestamp.equals(edaDiffD.evtStartTimestamp) : edaDiffD.evtStartTimestamp != null)
            return false;
        if (evtEndTimestamp != null ? !evtEndTimestamp.equals(edaDiffD.evtEndTimestamp) : edaDiffD.evtEndTimestamp != null)
            return false;
        if (gpCnt != null ? !gpCnt.equals(edaDiffD.gpCnt) : edaDiffD.gpCnt != null) return false;
        if (oraCnt != null ? !oraCnt.equals(edaDiffD.oraCnt) : edaDiffD.oraCnt != null) return false;
        if (difference != null ? !difference.equals(edaDiffD.difference) : edaDiffD.difference != null) return false;
        if (updateTime != null ? !updateTime.equals(edaDiffD.updateTime) : edaDiffD.updateTime != null) return false;
        if (remark != null ? !remark.equals(edaDiffD.remark) : edaDiffD.remark != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result = id;
        result = 31 * result + (shop != null ? shop.hashCode() : 0);
        result = 31 * result + (ope != null ? ope.hashCode() : 0);
        result = 31 * result + (eqpt != null ? eqpt.hashCode() : 0);
        result = 31 * result + (evtStartTimestamp != null ? evtStartTimestamp.hashCode() : 0);
        result = 31 * result + (evtEndTimestamp != null ? evtEndTimestamp.hashCode() : 0);
        result = 31 * result + (gpCnt != null ? gpCnt.hashCode() : 0);
        result = 31 * result + (oraCnt != null ? oraCnt.hashCode() : 0);
        result = 31 * result + (difference != null ? difference.hashCode() : 0);
        result = 31 * result + (updateTime != null ? updateTime.hashCode() : 0);
        result = 31 * result + (remark != null ? remark.hashCode() : 0);
        return result;
    }
}
